$(document).ready(function () {
    var uid = sessionStorage.getItem("uid");
    var uid = 1;
    alert(uid);
    $.get("address/findbasic", {"uid": uid}, function (basics) {
        $("[id='basicinfo']").empty();
        for (var i = 0; i < basics.length; i++) {
            $(" <li><span>用户名：</span>" + basics[i].username + "</li>\n" +
                "   <li><span>联系方式：</span>"+basics[i].phone+"</li>\n" +
                " <li><span>联系地址：</span>"+basics[i].detailedaddress+"</li>").appendTo("[id='basicinfo']")
        }
    });

/*    $.get("basic/findAll", function (all) {
        $("[id='nearview']").empty();
        for (var i = 0; i < all.length; i++) {
            $("<li>" +
                "<a href='detail.html'><img src='"+all[i].img+"'></a>" +
                "<h4><a href='detail.html'>"+all[i].name+"</a></h4>" +
                "<div class='operate'>" +
                "<span class='prize'>￥"+all[i].price+"</span>" +
                "<span class='unit'>"+all[i].price+"/500g</span>" +
                "<a href='#' class='add_goods' title='加入购物车'></a>" +
                "</div>" +
                "</li>").appendTo("[id='nearview']")
        }
    });*/
});